<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<!--
        	作者：13024022425@163.com
        	时间：2017-10-23
        	描述：引入angularjs
        -->
	<script src="../js/angular.min.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<div ng-app="myApp" ng-controller="myCtrl">
			<input type="text" ng-model="username" />
				<div>hello:<span>{{username}}</span></div>
				<div>hello:<span ng-bind="username"></span></div>
		</div>
		<script type="text/javascript">
			//获取模块对象：相当于java的myApp=getModel(myApp)方法获取模块
			var myApp = angular.module("myApp",[]);
			//在模块对象上初始化控制器
			myApp.controller('myCtrl',['$scope',function ($scope) {
				$scope.username='传智播客';
			}]);
		</script>
	</body>
</html>
